#ifndef MAINWIDGET_H
#define MAINWIDGET_H

#include <QWidget>
#include <QUdpSocket>
#include "DialogAbout.h"
namespace Ui {
class MainWidget;
}

class MainWidget : public QWidget
{
    Q_OBJECT

public:
    explicit MainWidget(QWidget *parent = 0);
    ~MainWidget();

private slots:
    void on_btn_init_clicked();

    void on_btn_close_clicked();

    void on_btn_send_clicked();

    void onReadyRead();
    void on_tbtn_about_clicked();


    void on_checkBox_send_clicked(bool checked);

private:
    Ui::MainWidget *ui;
    QUdpSocket* m_sendSocket;
    QUdpSocket* m_recvSocket;

    QHostAddress m_addr;
    int m_sendPort;
    int m_recvPort;
    int m_count;

    DialogAbout * m_aboutDialog;
};

#endif // MAINWIDGET_H
